package com.wyc.serviceMap.controller;

import com.wyc.internalCommon.result.ApiResult;
import com.wyc.serviceMap.service.ServiceFromMapService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 轨迹服务id
 */
@RestController
@RequestMapping("/service")
public class ServiceController {

    @Autowired
    private ServiceFromMapService serviceFromMapService;

    /**
     * 创建轨迹服务
     * @param name
     * @return
     */
    @PostMapping("/add")
    public ApiResult add(String name){
        return serviceFromMapService.add(name);
    }

}
